<!DOCTYPE html>
<html>
<head>
<title>{$site_name}</title>
<meta name="keywords" content="{$site_seo_keywords}" />
<meta name="description" content="{$site_seo_description}">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <tc_include file="Public:member_head" />
</head>

<body class="body-white">
<script type="text/javascript">
    var webPath = {webRoot: ""};
    $(function () {
        $(".returnLog").click(function () {
            $('.rebateLog').removeClass('cur');
            $('.returnLog').addClass('cur');
            $("#rebate_div").hide();
            $("#return_div").fadeIn(500);
            $("#isReturn").attr("value","Y")
            $(".returnGood").removeClass('cur');
        });
        $(".rebateLog").click(function () {
            $('.returnLog').removeClass('cur');
            $('.rebateLog').addClass('cur');
            $("#return_div").hide();
            $("#rebate_div").fadeIn(500);
            $("#isReturn").attr("value","N");
            $(".returnGood").removeClass('cur');
        });
    });

    /*填写物流单号操作*/
    var showLogistics = function (id,type) {
        $("#logistics").val("");
        $("#tipAddr").dialog({
            buttons: {'确定': function () {
                var logistics = jQuery.trim($("#logistics").val());
                if (logistics == null || logistics == '') {
                    showDialog("请填写物流单号");
                    return;
                }
                var companyNm = jQuery.trim($("#companyNm").val());
                if (companyNm == null || companyNm == '') {
                    showDialog("请填写物流单号");
                    return;
                }
                addLogistics(id, logistics, companyNm,type);
            }
            }});
    }

    var addLogistics = function (id, logistics, companyNm,type) {
        $.ajaxSettings['contentType'] = "application/x-www-form-urlencoded; charset=utf-8";
        $.post(webPath.webRoot + "/member/addReturnedAddr.json", {returnId: id, logisticsOrderCode: logistics, logisticsCompany: companyNm, isReturn: $("#isReturn").val()}, function () {
            $("#tipAddr").dialog("close");
            setTimeout(function () {
                window.location.href = webPath.webRoot+"/module/member/returnedPurchase.ac?type="+type;
            }, 1)
        })
    }

    //显示层 start
    var showDialog = function (text) {
        $("#tiptext").html(text);
        $("#tip").dialog({
            buttons: {
                '确定': function () {
                    $("#tip").dialog("close")
                }
            }
        });
    }
    /*填写物流单号操作*/
</script>

	<tc_include file="Public:nav" />


    <!--会员中心-->
    <div class="member">

        <!--所在位置-->
        <tc_include file="Public:position" />
        <!--end 所在位置-->

        <!--会员中心首页-->
        <div class="memberbox">
            <!--会员中心左边-->
            <tc_include file="Public:menu_left" />
            <!--end 会员中心左边-->

            <!--会员中心右边-->
            <div class="memberR">
                <!--密码修改-->
                <div class="r-titleTb"><h2>退换货记录</h2></div>
                <!--退换货记录-->
                <div class="minute-menu">
                    <h2><a href="javascript:void(0);" class="returnLog <if condition="I('get.type') != 1">cur</if>">退货记录</a></h2>
                    <h2><a href="javascript:void(0);" class="rebateLog ">换货记录</a></h2>
                    <h2><a href="{:U('product/member/refund',array('type'=>1))}" class='returnGood <if condition="I('get.type') == 1">cur</if>'>申请退换货</a></h2>
                </div>
                <input type="hidden" id="isReturn" value="Y">
                <div class="notice">
                    <div class="n-title"><em></em>退换货须知：</div>
                    <div class="n-text">
                        <p>1、选择订单下单商品进行退换货；</p>

                        <p>2、请您写明退换原因（相关信息请及时与我们工作人员联系）。</p>

                        <p>3、将商品随同发票、发货单一并邮寄至：<br>

                            &nbsp;&nbsp;&nbsp;&nbsp;地址：<br>
                            &nbsp;&nbsp;&nbsp;&nbsp;电话：</p>
                    </div>
                </div>

                <!--start 退货记录-->

                <div class="order-box" id="return_div">
                    <div class="order">
                        <if condition="I('get.type') == 1">
                            <table cellspacing="0" cellpadding="0" border="0" class="o-table">
                                <thead class="o-thead">
                                <tr class="o-title">
                                    <td style="width:129px;">订单编号</td>
                                    <td style="width:597px;">商品名称</td>
                                    <td style="width:129px;">下单时间</td>
                                    <td style="width:168px;">操作</td>
                                </tr>
                                </thead>
                                <tbody class="o-info">

                                </tbody>
                            </table>
                        <else/>
                            <table cellspacing="0" cellpadding="0" border="0" class="o-table">
                                <thead class="o-thead">
                                <tr class="o-title">
                                    <td style="width:129px;">退货订单号</td>
                                    <td style="width:102px;">订单号</td>
                                    <td style="width:231px;">图片文件</td>
                                    <td style="width:142px;">物流信息</td>
                                    <td style="width:100px;">申请时间</td>
                                    <td style="width:79px;">状态</td>
                                    <td style="width:239px;">操作</td>
                                </tr>
                                </thead>
                                <tbody class="o-info">

                                </tbody>
                            </table>
                        </if>
                    </div>
                </div>
                <!--end 退货记录-->


                <!--start 换货记录-->
                <div class="order-box" id="rebate_div" style="display: none;">
                    <div class="order">
                        <table cellspacing="0" cellpadding="0" border="0" class="o-table">
                            <thead class="o-thead">
                            <tr class="o-title">
                                <td style="width:129px;">换货订单号</td>
                                <td style="width:102px;">订单号</td>
                                <td style="width:231px;">图片文件</td>
                                <td style="width:142px;">物流信息</td>
                                <td style="width:100px;">申请时间</td>
                                <td style="width:79px;">状态</td>
                                <td style="width:239px;">操作</td>
                            </tr>
                            </thead>
                            <tbody class="o-info">


                            </tbody>
                        </table>
                    </div>
                </div>
                <!--end 换货记录-->
                <!--end 退换货记录-->
            </div>
            <!--end 会员中心右边-->
            <div class="clear"></div>
        </div>
        <!--end 会员中心首页-->
        <div class="clear"></div>
    </div>
    <!--end 会员中心-->

    <tc_include file="Public:member_footer" />

	<tc_include file="Public:footer" />

</body>
</html>